package com.ruoyi.canteen.domain;

import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;
/**
 * @author: 杨祥
 * @date: 2025/04/10/14:35
 * @description:
 */

public class ConsumTransaction {

    @JsonProperty("Order")
    private String order;

    @JsonProperty("CardNo")
    private String cardNo;

    @JsonProperty("CardMode")
    private Integer cardMode;

    @JsonProperty("Mode")
    private Integer mode;

    @JsonProperty("PayType")
    private Integer payType;

    @JsonProperty("Amount")
    private String amount;

    @JsonProperty("Menus")
    private List<Menu> menus;

    public ConsumTransaction() {
    }

    public ConsumTransaction(String order, String cardNo, Integer cardMode, Integer mode, String amount, Integer payType, List<Menu> menus) {
        this.order = order;
        this.cardNo = cardNo;
        this.cardMode = cardMode;
        this.mode = mode;
        this.amount = amount;
        this.payType = payType;
        this.menus = menus;
    }

    public ConsumTransaction(String order, String cardNo, Integer cardMode, Integer mode, Integer payType, String amount) {
        this.order = order;
        this.cardNo = cardNo;
        this.cardMode = cardMode;
        this.mode = mode;
        this.payType = payType;
        this.amount = amount;
    }

    public String getOrder() {
        return order;
    }

    public void setOrder(String order) {
        this.order = order;
    }

    public String getCardNo() {
        return cardNo;
    }

    public void setCardNo(String cardNo) {
        this.cardNo = cardNo;
    }

    public Integer getCardMode() {
        return cardMode;
    }

    public void setCardMode(Integer cardMode) {
        this.cardMode = cardMode;
    }

    public Integer getMode() {
        return mode;
    }

    public void setMode(Integer mode) {
        this.mode = mode;
    }

    public Integer getPayType() {
        return payType;
    }

    public void setPayType(Integer payType) {
        this.payType = payType;
    }

    public String getAmount() {
        return amount;
    }

    public void setAmount(String amount) {
        this.amount = amount;
    }

    public List<Menu> getMenus() {
        return menus;
    }

    public void setMenus(List<Menu> menus) {
        this.menus = menus;
    }

    public static class Menu {

        @JsonProperty("MenuID")
        private String menuID;

        @JsonProperty("Count")
        private String count;

        public String getMenuID() {
            return menuID;
        }

        public void setMenuID(String menuID) {
            this.menuID = menuID;
        }

        public String getCount() {
            return count;
        }

        public void setCount(String count) {
            this.count = count;
        }
    }

    @Override
    public String toString() {
        return "ConsumTransaction{" +
                "order='" + order + '\'' +
                ", cardNo='" + cardNo + '\'' +
                ", cardMode=" + cardMode +
                ", mode=" + mode +
                ", payType=" + payType +
                ", amount='" + amount + '\'' +
                ", menus=" + menus +
                '}';
    }
}
